import 'package:flutter/material.dart';
import 'package:test1/View/MyRowText.dart';
import 'package:test1/pages/dartbase/Dart_Base_DataType_Page.dart';
import 'package:test1/pages/dartbase/Dart_Class_Page.dart';
import 'package:test1/pages/dartbase/Dart_Constants_Variables_Page.dart';
import 'package:test1/pages/dartbase/Dart_Function_Page.dart';

class DartBase_Page extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: Text("Dart基础"),
        ),
        body: ListView(
          children: <Widget>[
            MyRowText("变量和常量", () =>
                Navigator.push(
                    context, MaterialPageRoute(builder: (BuildContext context) {
                  return Dart_Constants_Variables_Page();
                }))
            ),
            MyRowText("Dart基本数据类型", () =>
                Navigator.push(
                    context, MaterialPageRoute(builder: (BuildContext context) {
                  return Dart_Base_DataType_Page();
                }))
            ),
            MyRowText("类的创建", () =>
                Navigator.push(
                    context, MaterialPageRoute(builder: (BuildContext context) {
                  return Dart_Class_Page();
                }))
            ),
            MyRowText("函数", () =>
                Navigator.push(
                    context, MaterialPageRoute(builder: (BuildContext context) {
                  return Dart_Function_Page();
                }))
            ),
          ],
        ),
      ),
    );
  }
}